package org.jeecg.modules.demo.caiWuSrOrder.entity;

import com.baomidou.mybatisplus.annotation.*;
import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;
import org.jeecg.common.aspect.annotation.Dict;
import org.jeecgframework.poi.excel.annotation.Excel;
import org.springframework.format.annotation.DateTimeFormat;

import java.io.Serializable;
import java.math.BigDecimal;
import java.util.Date;

/**
 * @Description: cw_sr_order
 * @Author: jeecg-boot
 * @Date:   2021-12-14
 * @Version: V1.0
 */
@Data
@TableName("cw_sr_order")
@Accessors(chain = true)
@EqualsAndHashCode(callSuper = false)
@ApiModel(value="cw_sr_order对象", description="cw_sr_order")
public class CwSrOrder implements Serializable, Comparable<CwSrOrder> {
    private static final long serialVersionUID = 1L;

	/**id*/
	@TableId(type = IdType.ASSIGN_ID)
    @ApiModelProperty(value = "id")
    private String id;
	/**收入单号*/
	@Excel(name = "收入单号", width = 15)
    @ApiModelProperty(value = "收入单号")
    private String srNo;
	/**部门*/
	@Excel(name = "部门", width = 15)
    @ApiModelProperty(value = "部门")
    @Dict(dictTable = "sys_depart",dicCode ="id",dicText="depart_name")
    private String dept;
	/**单据日期*/
	@Excel(name = "单据日期", width = 15, format = "yyyy-MM-dd")
	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd")
    @DateTimeFormat(pattern="yyyy-MM-dd")
    @ApiModelProperty(value = "单据日期")
    private Date puCdate;
	/**业务类型(1往来收入2现金收入)*/
	@Excel(name = "业务类型(1往来收入2现金收入)", width = 15)
    @ApiModelProperty(value = "业务类型(1往来收入2现金收入)")
    private String ywType;
	/**业务员*/
	@Excel(name = "业务员", width = 15)
    @ApiModelProperty(value = "业务员")
    @Dict(dictTable = "sys_user",dicCode ="id",dicText="realname")
    private String ywName;
	/**收入名称*/
	@Excel(name = "收入名称", width = 15)
    @ApiModelProperty(value = "收入名称")
    @Dict(dicCode="srType")
    private String srName;
	/**使用预收*/
	@Excel(name = "使用预收", width = 15)
    @ApiModelProperty(value = "使用预收")
    private String syyf;
	/**收入编码*/
	@Excel(name = "收入编码", width = 15)
    @ApiModelProperty(value = "收入编码")
    private String srCode;
	/**项目*/
	@Excel(name = "项目", width = 15)
    @ApiModelProperty(value = "项目")
    @Dict(dictTable = "pj_project",dicCode ="id",dicText="pj_name")
    private String xm;
    /**创建日期*/
    @JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
    @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
    @ApiModelProperty(value = "创建日期")
    private Date createTime;
	/**累计结款金额*/
	@Excel(name = "累计结款金额", width = 15)
    @ApiModelProperty(value = "累计结款金额")
    private BigDecimal ljjkJine;
	/**结算方式*/
	@Excel(name = "结算方式", width = 15)
    @ApiModelProperty(value = "结算方式")
    private String jsType;
	/**账号名称*/
	@Excel(name = "账号名称", width = 15)
    @ApiModelProperty(value = "账号名称")
    private String zhName;
	/**现结金额*/
	@Excel(name = "现结金额", width = 15)
    @ApiModelProperty(value = "现结金额")
    private BigDecimal xjJine;
	/**关联单号*/
	@Excel(name = "关联单号", width = 15)
    @ApiModelProperty(value = "关联单号")
    private String glNo;
	/**销售订单号*/
	@Excel(name = "销售订单号", width = 15)
    @ApiModelProperty(value = "销售订单号")
    private String soNo;
	/**税率%*/
	@Excel(name = "税率%", width = 15)
    @ApiModelProperty(value = "税率%")
    @Dict(dicCode = "tax_rate")
    private BigDecimal shuilv;
	/**金额*/
	@Excel(name = "金额", width = 15)
    @ApiModelProperty(value = "金额")
    private BigDecimal jine;
	/**税额*/
	@Excel(name = "税额", width = 15)
    @ApiModelProperty(value = "税额")
    private BigDecimal shuie;
	/**含税金额*/
	@Excel(name = "含税金额", width = 15)
    @ApiModelProperty(value = "含税金额")
    private BigDecimal srTax;
	/**票据类型*/
	@Excel(name = "票据类型", width = 15)
    @ApiModelProperty(value = "票据类型")
    private Integer pjType;
	/**往来单位*/
	@Excel(name = "往来单位", width = 15)
    @ApiModelProperty(value = "往来单位")
    private String wldw;
    /**订单状态（0：未审，1：已审，2：已关闭）*/
    @Excel(name = "订单状态（0：未审，1：已审，2：已关闭）", width = 15)
    @ApiModelProperty(value = "订单状态（0：未审，1：已审，2：已关闭）")
    private Integer soStatus;
    /**删除状态（0：未删，1：已删）*/
    @Excel(name = "删除状态（0：未删，1：已删）", width = 15)
    @ApiModelProperty(value = "删除状态（0：未删，1：已删）")
    private Integer isDelete;
    /**附件*/
    @Excel(name = "附件", width = 15)
    @ApiModelProperty(value = "附件")
    private String fj;
    /**客户*/
    @Excel(name = "客户", width = 15)
    @ApiModelProperty(value = "客户")
    private String soCustom;
    /**备注*/
    @Excel(name = "备注", width = 15)
    @ApiModelProperty(value = "备注")
    private String remark;
    /**审核人*/
    @Excel(name = "审核人", width = 15)
    @ApiModelProperty(value = "审核人")
    @Dict(dictTable = "sys_user",dicCode ="id",dicText="realname")
    private String shName;
    /**审核时间*/
    @Excel(name = "审核时间", width = 15)
    @ApiModelProperty(value = "审核时间")
    @TableField(updateStrategy = FieldStrategy.IGNORED)
    private Date shTime;
    /**租户id*/
    @Excel(name = "租户id", width = 15)
    @ApiModelProperty(value = "租户id")
    private Integer tenantId;
    /**内部编号*/
    @Excel(name = "内部编号", width = 15)
    @ApiModelProperty(value = "内部编号")
    private String tradecode;
    /**创建人*/
    @ApiModelProperty(value = "创建人")
    private String createBy;
    /**机构编码*/
    @ApiModelProperty(value = "机构编码")
    private String sysOrgCode;


    @Override
    public int compareTo(CwSrOrder o) {
        return o.getCreateTime().compareTo(this.createTime);
    }
}
